﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace Randata.Test
{
    [TestClass]
    public class BoolTest
    {

        [TestMethod]
        public void BoolDataProvider_Should_work()
        {
            bool b = DataProvider.Any<bool>();
        }

        [TestMethod]
        public void BoolDataProvider_Should_give_diferent_values()
        {
            int trueCount = 0;
            int falseCount = 0;

            for (int i = 0; i < 100; i++)
            {
                if(DataProvider.Any<bool>())
                    trueCount++;
                else
                    falseCount++;
            }

            Assert.IsTrue(trueCount > 0, "The values must to be diferents.");
            Assert.IsTrue(falseCount > 0, "The values must to be diferents.");
        }

    }
}
